package com.wondersgroup.fjzlpt.org.dao.impl.xymb;

import com.quick.framework.boot.repository.sql.bean.SQLBean;
import com.quick.framework.boot.repository.sql.bean.table.TableBean;
import com.quick.framework.boot.repository.sql.jdbcTemplate.impl.BaseJTDAOImpl;
import com.wondersgroup.fjzlpt.org.dao.inter.xymb.XyfwxxDAO;
import com.wondersgroup.fjzlpt.org.dao.inter.xymb.XymbDAO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Repository;

/**
 * Created by lion on 2017/7/4.
 */
@Repository
public class XyfwxxDAOImpl extends BaseJTDAOImpl implements XyfwxxDAO{

    @Override
    @Autowired
    @Qualifier("TB_XXWH_XYFWXX")
    public void setTb(TableBean tb) {
        super.setTb(tb);
    }

    public void deleteByXYMBID(String XYMBID){
        StringBuilder sbud = new StringBuilder("delete from ")
                .append(this.tb.getTableName()).append(" where XYMBID=?");
        SQLBean sb = new SQLBean(sbud.toString(), new Object[]{XYMBID});
        this.update(sb);
    }
}
